package com.version1_4.controller;

import com.version1_3.controller.ShareController;
import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by reeveslee on 16/4/27.
 */
@Controller
public class ShareController1_4 {
    private static final Logger LOGGER = Logger.getLogger(ShareController1_4.class);

    @Autowired
    private ShareController shareController;

    /**
     * 在APP外记录文章被用户阅读
     */
    @RequestMapping(value = "/version1_4/share/getPageInfo/{pageId}", method = RequestMethod.GET, produces = "text/html;charset=UTF-8")
    @ResponseBody
    public String getPageInfo(@PathVariable("pageId") int pageId) {
        return shareController.getPageInfo(pageId);
    }
}
